package com.summatech.gwt.mvp.client.presenter;

import com.google.gwt.user.client.ui.IsWidget;
import com.mvp4g.client.annotation.Presenter;
import com.mvp4g.client.presenter.BasePresenter;
import com.summatech.gwt.mvp.client.MultiPresentersEventBus;
import com.summatech.gwt.mvp.client.presenter.RootPresenter.IRootView;
import com.summatech.gwt.mvp.client.view.RootView;

@Presenter(view = RootView.class)
public class RootPresenter extends
		BasePresenter<IRootView, MultiPresentersEventBus> {

	public interface IRootView {
		void addWidget(IsWidget widget);
	}
	
	public void onInit(){
		eventBus.createPresenters();
	}
	
	public void onDisplayWidget(IsWidget widget) {
			view.addWidget(widget);
	}

}
